#include<stdio.h>
int main()
{
	int a,n,basic,sum=0;
	scanf("%d %d",&n,&a);
	basic=a;
	for(int i=0;i<n;i++) {
		sum+=basic;
		basic=basic*10+a;
	}
	printf("%d\n",sum);
	return 0;
}
